/* uDig - User Friendly Desktop Internet GIS client
 * http://udig.refractions.net
 * (C) 2004-2008, Refractions Research Inc.
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation;
 * version 2.1 of the License.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 */
package symbology;
import feature.Feature;

/**
 * TODO Purpose of 
 * <p>
 *
 * </p>
 * @author John
 * @since 1.1.0
 */
public class TestParseApl {

    public static void main(String[] args)
    {
        // Parse the .apl file to create a symbolizer
        ParseApl parser = new ParseApl();
        Object o;
        try {
            o = parser.parse(args[0]);
        } catch (Exception e) {
            e.printStackTrace();
            return;
        }
        
        // Apply the symbolizer to a feature (and scale) to get a set of symbols
        Feature feature = new Feature();
        Symbolizer symbolizer = (Symbolizer)o;
        
        Symbols symbols = new Symbols();
        symbolizer.addSymbols(feature, 100000, symbols);
        
        for (Symbol s: symbols)
            System.out.printf("%s\n", s.getClass().getName());
    }
}
